import request from '@/request/index.js';

export function createHealthRecord(params) {
	return request.post({
		url: '/app-api/user/healthy-log/create',
		data: params || {},
		custom: {
			title: "新增健康档案",
			authentication: true
		}
	});
}
export function updateHealthRecord(params) {
	return request.post({
		url: '/app-api/user/healthy-log/update',
		params: params || {},
		custom: {
			title: "更新健康档案",
			authentication: true
		}
	});
}
export function getHealthRecord(params) {
	return request.get({
		url: '/app-api/user/healthy-log/home',
		params: params || {},
		custom: {
			title: "获取健康档案",
			authentication: true
		}
	});
}

export function getCurrentDateDetail(params) {
	return request.post({
		url: '/app-api/user/healthy-log/get-measurement-by-date',
		data: params || {},
		custom: {
			title: "按日期获取健康档案数据",
			authentication: true
		}
	});
}